<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    Set 对象：存储唯一值
    <script>
        //数组去重  1.循环   2.Set对象
        var arr=[1,1,2,3,4,4,4,5];
        var seta=new Set(arr);
        console.log(Array.from(seta));
    </script>
</body>
</html>